-
Notifications
You must be signed in to change notification settings - Fork 13.6k
[SPARC][IAS] Add movr(n)e alias for movr(n)z #94252
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[SPARC][IAS] Add movr(n)e alias for movr(n)z #94252
Conversation
Created using spr 1.3.4 [skip ci]
Created using spr 1.3.4
@llvm/pr-subscribers-mc Author: Koakuma (koachan) ChangesThis adds the alternate mnemonics for movrz and movrnz. Full diff: https://github.com/llvm/llvm-project/pull/94252.diff 2 Files Affected:
diff --git a/llvm/lib/Target/Sparc/SparcInstrAliases.td b/llvm/lib/Target/Sparc/SparcInstrAliases.td
index 2b9244519f154..eedad25737f65 100644
--- a/llvm/lib/Target/Sparc/SparcInstrAliases.td
+++ b/llvm/lib/Target/Sparc/SparcInstrAliases.td
@@ -400,9 +400,11 @@ defm : cp_cond_alias<"012", 0b1111>;
let EmitPriority = 0 in defm : cp_cond_alias<"", 0b1000>; // same as a; gnu asm, not in manual
defm : reg_cond_alias<"z", 0b001>;
+defm : reg_cond_alias<"e", 0b001>;
defm : reg_cond_alias<"lez", 0b010>;
defm : reg_cond_alias<"lz", 0b011>;
defm : reg_cond_alias<"nz", 0b101>;
+defm : reg_cond_alias<"ne", 0b101>;
defm : reg_cond_alias<"gz", 0b110>;
defm : reg_cond_alias<"gez", 0b111>;
diff --git a/llvm/test/MC/Sparc/sparc64-ctrl-instructions.s b/llvm/test/MC/Sparc/sparc64-ctrl-instructions.s
index a21b17552eb15..188947314f4b7 100644
--- a/llvm/test/MC/Sparc/sparc64-ctrl-instructions.s
+++ b/llvm/test/MC/Sparc/sparc64-ctrl-instructions.s
@@ -1190,29 +1190,37 @@
! CHECK-NEXT: ! fixup A - offset: 0, value: .BB0, kind: fixup_sparc_br16
brz,a,pn %g1, .BB0
+ ! CHECK: movrz %g1, %g2, %g3 ! encoding: [0x87,0x78,0x44,0x02]
! CHECK: movrz %g1, %g2, %g3 ! encoding: [0x87,0x78,0x44,0x02]
! CHECK: movrlez %g1, %g2, %g3 ! encoding: [0x87,0x78,0x48,0x02]
! CHECK: movrlz %g1, %g2, %g3 ! encoding: [0x87,0x78,0x4c,0x02]
! CHECK: movrnz %g1, %g2, %g3 ! encoding: [0x87,0x78,0x54,0x02]
+ ! CHECK: movrnz %g1, %g2, %g3 ! encoding: [0x87,0x78,0x54,0x02]
! CHECK: movrgz %g1, %g2, %g3 ! encoding: [0x87,0x78,0x58,0x02]
! CHECK: movrgez %g1, %g2, %g3 ! encoding: [0x87,0x78,0x5c,0x02]
movrz %g1, %g2, %g3
+ movre %g1, %g2, %g3
movrlez %g1, %g2, %g3
movrlz %g1, %g2, %g3
movrnz %g1, %g2, %g3
+ movrne %g1, %g2, %g3
movrgz %g1, %g2, %g3
movrgez %g1, %g2, %g3
+ ! CHECK: movrz %g1, 2, %g3 ! encoding: [0x87,0x78,0x64,0x02]
! CHECK: movrz %g1, 2, %g3 ! encoding: [0x87,0x78,0x64,0x02]
! CHECK: movrlez %g1, 2, %g3 ! encoding: [0x87,0x78,0x68,0x02]
! CHECK: movrlz %g1, 2, %g3 ! encoding: [0x87,0x78,0x6c,0x02]
! CHECK: movrnz %g1, 2, %g3 ! encoding: [0x87,0x78,0x74,0x02]
+ ! CHECK: movrnz %g1, 2, %g3 ! encoding: [0x87,0x78,0x74,0x02]
! CHECK: movrgz %g1, 2, %g3 ! encoding: [0x87,0x78,0x78,0x02]
! CHECK: movrgez %g1, 2, %g3 ! encoding: [0x87,0x78,0x7c,0x02]
movrz %g1, 2, %g3
+ movre %g1, 2, %g3
movrlez %g1, 2, %g3
movrlz %g1, 2, %g3
movrnz %g1, 2, %g3
+ movrne %g1, 2, %g3
movrgz %g1, 2, %g3
movrgez %g1, 2, %g3
|
@llvm/pr-subscribers-backend-sparc Author: Koakuma (koachan) ChangesThis adds the alternate mnemonics for movrz and movrnz. Full diff: https://github.com/llvm/llvm-project/pull/94252.diff 2 Files Affected:
diff --git a/llvm/lib/Target/Sparc/SparcInstrAliases.td b/llvm/lib/Target/Sparc/SparcInstrAliases.td
index 2b9244519f154..eedad25737f65 100644
--- a/llvm/lib/Target/Sparc/SparcInstrAliases.td
+++ b/llvm/lib/Target/Sparc/SparcInstrAliases.td
@@ -400,9 +400,11 @@ defm : cp_cond_alias<"012", 0b1111>;
let EmitPriority = 0 in defm : cp_cond_alias<"", 0b1000>; // same as a; gnu asm, not in manual
defm : reg_cond_alias<"z", 0b001>;
+defm : reg_cond_alias<"e", 0b001>;
defm : reg_cond_alias<"lez", 0b010>;
defm : reg_cond_alias<"lz", 0b011>;
defm : reg_cond_alias<"nz", 0b101>;
+defm : reg_cond_alias<"ne", 0b101>;
defm : reg_cond_alias<"gz", 0b110>;
defm : reg_cond_alias<"gez", 0b111>;
diff --git a/llvm/test/MC/Sparc/sparc64-ctrl-instructions.s b/llvm/test/MC/Sparc/sparc64-ctrl-instructions.s
index a21b17552eb15..188947314f4b7 100644
--- a/llvm/test/MC/Sparc/sparc64-ctrl-instructions.s
+++ b/llvm/test/MC/Sparc/sparc64-ctrl-instructions.s
@@ -1190,29 +1190,37 @@
! CHECK-NEXT: ! fixup A - offset: 0, value: .BB0, kind: fixup_sparc_br16
brz,a,pn %g1, .BB0
+ ! CHECK: movrz %g1, %g2, %g3 ! encoding: [0x87,0x78,0x44,0x02]
! CHECK: movrz %g1, %g2, %g3 ! encoding: [0x87,0x78,0x44,0x02]
! CHECK: movrlez %g1, %g2, %g3 ! encoding: [0x87,0x78,0x48,0x02]
! CHECK: movrlz %g1, %g2, %g3 ! encoding: [0x87,0x78,0x4c,0x02]
! CHECK: movrnz %g1, %g2, %g3 ! encoding: [0x87,0x78,0x54,0x02]
+ ! CHECK: movrnz %g1, %g2, %g3 ! encoding: [0x87,0x78,0x54,0x02]
! CHECK: movrgz %g1, %g2, %g3 ! encoding: [0x87,0x78,0x58,0x02]
! CHECK: movrgez %g1, %g2, %g3 ! encoding: [0x87,0x78,0x5c,0x02]
movrz %g1, %g2, %g3
+ movre %g1, %g2, %g3
movrlez %g1, %g2, %g3
movrlz %g1, %g2, %g3
movrnz %g1, %g2, %g3
+ movrne %g1, %g2, %g3
movrgz %g1, %g2, %g3
movrgez %g1, %g2, %g3
+ ! CHECK: movrz %g1, 2, %g3 ! encoding: [0x87,0x78,0x64,0x02]
! CHECK: movrz %g1, 2, %g3 ! encoding: [0x87,0x78,0x64,0x02]
! CHECK: movrlez %g1, 2, %g3 ! encoding: [0x87,0x78,0x68,0x02]
! CHECK: movrlz %g1, 2, %g3 ! encoding: [0x87,0x78,0x6c,0x02]
! CHECK: movrnz %g1, 2, %g3 ! encoding: [0x87,0x78,0x74,0x02]
+ ! CHECK: movrnz %g1, 2, %g3 ! encoding: [0x87,0x78,0x74,0x02]
! CHECK: movrgz %g1, 2, %g3 ! encoding: [0x87,0x78,0x78,0x02]
! CHECK: movrgez %g1, 2, %g3 ! encoding: [0x87,0x78,0x7c,0x02]
movrz %g1, 2, %g3
+ movre %g1, 2, %g3
movrlez %g1, 2, %g3
movrlz %g1, 2, %g3
movrnz %g1, 2, %g3
+ movrne %g1, 2, %g3
movrgz %g1, 2, %g3
movrgez %g1, 2, %g3
|
Note: this PR was created by |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Created using spr 1.3.5 [skip ci]
Created using spr 1.3.5
This adds the alternate mnemonics for movrz and movrnz.